{
	"info": {
		"_postman_id": "0a798151-a282-4ce7-837e-c0d6011c4064",
		"name": "tasklist",
		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
		"_exporter_id": "24124777"
	},
	"item": [
		{
			"name": "Auth",
			"item": [
				{
					"name": "login",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {",
									"    pm.response.to.have.status(200);",
									"});",
									"",
									"pm.test(\"Check body\", function () {",
									"    var jsonData = pm.response.json();",
									"    pm.expect(jsonData.username).to.exist;",
									"    pm.expect(jsonData.accessToken).to.exist;",
									"    pm.expect(jsonData.refreshToken).to.exist;",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						},
						{
							"listen": "prerequest",
							"script": {
								"exec": [
									""
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "noauth"
						},
						"method": "POST",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"username\": \"william.emard@gmailRU.com\",\r\n    \"password\": \"123456\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/auth/login",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"auth",
								"login"
							]
						}
					},
					"response": []
				},
				{
					"name": "refreshTokens",
					"event": [
						{
							"listen": "prerequest",
							"script": {
								"exec": [
									""
								],
								"type": "text/javascript",
								"packages": {}
							}
						},
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.username).to.exist;\r",
									"    pm.expect(jsonData.accessToken).to.exist;\r",
									"    pm.expect(jsonData.refreshToken).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "noauth"
						},
						"method": "POST",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"refreshToken\": \"eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTE2NCwiZXhwIjoxNzE3NDkyOTY0fQ.nuqc4KfYJKz6EsGMtZgGte-4toqvr8Bv6bgtZyKHLfU\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/auth/refresh",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"auth",
								"refresh"
							]
						},
						"description": "### Refresh Access Token\n\nThis endpoint is used to refresh the access token by providing the refresh token.\n\n**Request Body**\n\n- refreshToken (string, required): The refresh token used to obtain a new access token.\n    \n\n**Response**  \nThe response will include the new access token and its expiration time."
					},
					"response": []
				}
			]
		},
		{
			"name": "User",
			"item": [
				{
					"name": "createUser",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.name).to.exist;\r",
									"    pm.expect(jsonData.username).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "noauth"
						},
						"method": "POST",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"name\": \"test\",\r\n    \"username\": \"test@gmail.com\",\r\n    \"password\": \"123456\",\r\n    \"passwordConfirmation\": \"123456\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/auth/register",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"auth",
								"register"
							]
						}
					},
					"response": []
				},
				{
					"name": "updateUser",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.name).to.exist;\r",
									"    pm.expect(jsonData.username).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTE2NCwiZXhwIjoxNzE3NDkyOTY0fQ.nuqc4KfYJKz6EsGMtZgGte-4toqvr8Bv6bgtZyKHLfU",
									"type": "string"
								}
							]
						},
						"method": "PUT",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"id\": \"3\",\r\n    \"name\": \"updatedTest\",\r\n    \"username\": \"updatedTest@gmail.com\",\r\n    \"password\": \"654321\",\r\n    \"passwordConfirmation\": \"654321\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/users",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"users"
							]
						}
					},
					"response": []
				},
				{
					"name": "getUserById",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.name).to.exist;\r",
									"    pm.expect(jsonData.username).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTE2NCwiZXhwIjoxNzE3NDkyOTY0fQ.nuqc4KfYJKz6EsGMtZgGte-4toqvr8Bv6bgtZyKHLfU",
									"type": "string"
								}
							]
						},
						"method": "GET",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/api/v1/users/3",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"users",
								"3"
							]
						}
					},
					"response": []
				},
				{
					"name": "deleteUserById",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Expect no response body\", function () {\r",
									"    pm.expect(pm.response.text()).to.be.empty;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTE2NCwiZXhwIjoxNzE3NDkyOTY0fQ.nuqc4KfYJKz6EsGMtZgGte-4toqvr8Bv6bgtZyKHLfU",
									"type": "string"
								}
							]
						},
						"method": "DELETE",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/api/v1/users/3",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"users",
								"3"
							]
						}
					},
					"response": []
				}
			]
		},
		{
			"name": "Task",
			"item": [
				{
					"name": "createTask",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.title).to.exist;\r",
									"    pm.expect(jsonData.description).to.exist;\r",
									"    pm.expect(jsonData.status).to.exist;\r",
									"    pm.expect(jsonData.expirationDate).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTcxNSwiZXhwIjoxNzE3NDkzNTE1fQ.Ye_jkRrKxL2sQIytO-tRrUV-ZT4UHIrwXIPITxOSsws",
									"type": "string"
								}
							]
						},
						"method": "POST",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"title\": \"title\",\r\n    \"description\": \"description\",\r\n    \"expirationDate\": \"2024-12-31 10:00\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/users/1/tasks",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"users",
								"1",
								"tasks"
							]
						}
					},
					"response": []
				},
				{
					"name": "updateTask",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.title).to.exist;\r",
									"    pm.expect(jsonData.description).to.exist;\r",
									"    pm.expect(jsonData.status).to.exist;\r",
									"    pm.expect(jsonData.expirationDate).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTcxNSwiZXhwIjoxNzE3NDkzNTE1fQ.Ye_jkRrKxL2sQIytO-tRrUV-ZT4UHIrwXIPITxOSsws",
									"type": "string"
								}
							]
						},
						"method": "PUT",
						"header": [],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"id\": \"5\",\r\n    \"title\": \"updatedTitle\",\r\n    \"description\": \"updatedDescription\",\r\n    \"status\": \"DONE\",\r\n    \"expirationDate\": \"2025-01-01 10:00\"\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "http://localhost:8080/api/v1/tasks",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"tasks"
							]
						}
					},
					"response": []
				},
				{
					"name": "getTaskById",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check body\", function () {\r",
									"    var jsonData = pm.response.json();\r",
									"    pm.expect(jsonData.id).to.exist;\r",
									"    pm.expect(jsonData.title).to.exist;\r",
									"    pm.expect(jsonData.description).to.exist;\r",
									"    pm.expect(jsonData.status).to.exist;\r",
									"    pm.expect(jsonData.expirationDate).to.exist;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTcxNSwiZXhwIjoxNzE3NDkzNTE1fQ.Ye_jkRrKxL2sQIytO-tRrUV-ZT4UHIrwXIPITxOSsws",
									"type": "string"
								}
							]
						},
						"method": "GET",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/api/v1/tasks/5",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"tasks",
								"5"
							]
						}
					},
					"response": []
				},
				{
					"name": "getTasksByUserId",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Check response body\", function () {\r",
									"    const responseData = pm.response.json();\r",
									"\r",
									"    pm.expect(responseData).to.be.an('array');\r",
									"    responseData.forEach(function(task) {\r",
									"        pm.expect(task).to.have.property('id');\r",
									"        pm.expect(task).to.have.property('title');\r",
									"        pm.expect(task).to.have.property('description');\r",
									"        pm.expect(task).to.have.property('status');\r",
									"        pm.expect(task).to.have.property('expirationDate');\r",
									"    });\r",
									"});\r",
									""
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTcxNSwiZXhwIjoxNzE3NDkzNTE1fQ.Ye_jkRrKxL2sQIytO-tRrUV-ZT4UHIrwXIPITxOSsws",
									"type": "string"
								}
							]
						},
						"method": "GET",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/api/v1/users/1/tasks",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"users",
								"1",
								"tasks"
							]
						}
					},
					"response": []
				},
				{
					"name": "deleteTaskById",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									"\r",
									"pm.test(\"Expect no response body\", function () {\r",
									"    pm.expect(pm.response.text()).to.be.empty;\r",
									"});"
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"auth": {
							"type": "bearer",
							"bearer": [
								{
									"key": "token",
									"value": "eyJhbGciOiJIUzI1NiJ9.eyJzY29wZXMiOlsiUk9MRV9VU0VSIiwiUk9MRV9BRE1JTiJdLCJzdWIiOiJ3aWxsaWFtLmVtYXJkQGdtYWlsUlUuY29tIiwiaXNzIjoiaHR0cHM6Ly90YXNrbGlzdC5leGFtcGxlLmNvbSIsImlhdCI6MTcxNzQ5MTcxNSwiZXhwIjoxNzE3NDkzNTE1fQ.Ye_jkRrKxL2sQIytO-tRrUV-ZT4UHIrwXIPITxOSsws",
									"type": "string"
								}
							]
						},
						"method": "DELETE",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/api/v1/tasks/5",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"api",
								"v1",
								"tasks",
								"5"
							]
						}
					},
					"response": []
				}
			]
		},
		{
			"name": "Actuator",
			"item": [
				{
					"name": "self",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {\r",
									"    pm.response.to.have.status(200);\r",
									"});\r",
									""
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/actuator",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"actuator"
							]
						}
					},
					"response": []
				},
				{
					"name": "health",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Status code is 200\", function () {    pm.response.to.have.status(200);});\r",
									""
								],
								"type": "text/javascript",
								"packages": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "http://localhost:8080/actuator/health",
							"protocol": "http",
							"host": [
								"localhost"
							],
							"port": "8080",
							"path": [
								"actuator",
								"health"
							]
						}
					},
					"response": []
				}
			]
		}
	],
	"event": [
		{
			"listen": "prerequest",
			"script": {
				"type": "text/javascript",
				"packages": {},
				"exec": [
					""
				]
			}
		},
		{
			"listen": "test",
			"script": {
				"type": "text/javascript",
				"packages": {},
				"exec": [
					""
				]
			}
		}
	]
}